The present invention relates to a system and method for reading and writing to magnetic stripe cards containing different bit densities.
Cards or fare media containing magnetic stripes store information or data on the magnetic stripe. Various types of information, such as account information for credit cards, personal information used by the Department of Motor Vehicles is stored on the magnetic stripe on driver licenses in some states and information relating to transit systems. For cards used in transit systems, information such as the monetary value remaining on the card, where a patron enters the transit system and where the patron exits the system can be stored on the magnetic stripe of the card. Upon exiting the transit system, the fee for the ride is automatically deducted from the card and the new value is encoded on the magnetic stripe.
Card readers are utilized to read the information from the card. There are different kinds of card readers, such as xe2x80x9cswipexe2x80x9d machines which a patron physically slides the card through and xe2x80x9cinsertionxe2x80x9d machines which capture the card and returns the card after completion of the transaction. The card readers are reading or decoding flux transitions off of the magnetic strip. A flux transition is a location (interface) on the magnetic stripe where the magnetic particles on the two sides of the interface have like poles facing each other, i.e. a South-South or a North-North interface, resulting in a concentration of magnetic flux at the interface. The combination of all these flux transitions represent the data stored on the card.
Flux transitions are encoded onto the magnetic stripe which is made of a ferromagnetic material. Ferromagnetic materials are substances that retain magnetism after an external magnetizing field is removed. This principle is the basis of all magnetic recording and playback. Magnetic poles always occur in pairs within magnetized material and magnetic flux lines emerge from the north pole and terminate at the south. The ferromagnetic material contain ferromagnetic particles, each of which acts like a tiny bar magnetic. The elemental magnetic particles are aligned with their North-South axes parallel to the magnetic stripe by means of an external magnetic field. If a magnetic particle is placed in a strong external magnetic field of the opposite polarity, it will reverse its own polarity (North becomes South, South becomes North. An unencoded magnetic stripe is a series of North-South magnetic particles.
However, if a South-South is created on the magnetic stripe, the fluxes will repel, and there will be a concentration of flux lines around the South-South interface (same with a North-North interface). Encoding the magnetic stripe on a card consists of creating South-South and North-North interfaces, and reading the card consists of detecting these flux transitions or flux reversals.
The external magnetic field used to flip the polarities is produced by a solenoid, which can reverse its polarity by reversing the direction of current. The field of the solenoid is concentrated across a gap in the solenoid, and when elemental magnetic particles of the magnetic stripe are exposed to this field, they polarize to the opposite (unlike poles attract). Movement of the stripe past the solenoid gap during which the polarity of the solenoid is reversed will produce a single flux reversal. To erase a magnetic stripe, the encoding head is held at a constant polarity and the entire stripe is moved past it. If there are no flux transitions, there is no data stored on the magnetic stripe.
Flux transitions are only created the instant the solenoid changes polarity. If the solenoid were to remain at is current polarity, no further flux reversals would be created as the magnetic stripe moves from right to left. If the solenoid gap polarity was changed from North-South to South-North, then a North-North flux transition would be instantly created. For each and every reversal in solenoid polarity, a single flux reversal is created. An encoded magnetic stripe is just a series of flux reversals (North-North followed by South-South followed by North-North).
Another solenoid called a read head is used to detect these flux transitions. The read head operates on the principle of electromagnetic reciprocity; current passing through a solenoid produces a magnetic field at the gap, therefore, the presence of a magnetic field at the gap of a solenoid coil will produce a current in the coil. The strongest magnetic fields on a magnetic stripe are at the points of flux transitions. These are detected as voltage peaks by the reader, with +/xe2x88x92 voltages corresponding to North-North/South-South flux transitions. Data is encoded in xe2x80x9cbit cellsxe2x80x9d, the frequency of which is the frequency of xe2x80x980xe2x80x99 signals. xe2x80x981xe2x80x99 signals are exactly twice the frequency of xe2x80x980xe2x80x99 signals
One of the problems with magnetic media is that different applications have different requirements in terms of bit density and encoding format. Differences in the requirements cause time consuming and expensive changes to media reader/writers. As such, media reader/writers can only accept cards of a specific bit density.
It is one object of the present invention to provide a system that requires no knowledge of the bit density or data format of the media being processed.
It is another object of the present invention to encode and decode data onto the magnetic stripe of a card at any bit density.
In the present invention, a method or process of decoding and encoding information on the magnetic stripes of cards of various bit densities is provided. In this method, a card is inserted into a card reader, placed onto a transport belt and passed under magnetic read/write heads for encoding or decoding. A shaft encoder is utilized to determine the velocity of the transport belt. The velocity of the belt is transmitted to a single board computer, over a high speed communications link, in the preamble of a message and is used to determine the bit density of the card. The data read from the card is sent to the single board computer in the body of the message.
The single board computer determines what the bit density of the card is and demodulates and decodes the data. To demodulate the data, the single board computer sends the data to a demodulator object that supports the bit density of the card. The demodulator object receives the data and converts the data to a data stream of ASCII characters representing the data that was encoded on the magnetic stripe of the card. If the single board computer does not have a demodulator object that can support the bit density of the card, a new demodulator object can be instantiated which supports this bit density. The data stream is then sent to a decoder object that decodes and unpacks the data stream. From there the data stream is sent to a ticket validator to check the validity of the data. If the data stream decoded and unpacked from the card is valid, this data is sent to a packer object where the data is packed into a magnetic stripe format and sent back to the card reader for encoding.
The foregoing, together with other features and advantages of the present invention, will become more apparent when referring to the following specification, claims and accompanying drawings.